﻿<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <title></title>
    </head>
    <body>

        <form action="/">
            <p>
                В момента са налични <span data-bind='text: offers().length'>&nbsp;</span> оферти:
            </p>
            <table data-bind='visible: offers().length > 0' border="1">
                <thead>
                    <tr>
                        <th>Информация за шофьора</th>
                        <th>Тръгване от:</th>
                        <th>Пристигане в:</th>
                        <th>Дата:</th>
                        <th>Цена:</th>
                        <th />
                    </tr>
                </thead>
                <tbody data-bind='foreach: offers'>
                    <tr>
                        <td data-bind="text: driver.fname + ' ' + driver.lname + ' ' + driver.email+ ' ' + driver.phone"> </td>
                        <td data-bind="text: trip.to"></td>
                        <td data-bind="text: trip.from"></td>
                        <td data-bind="text: trip.dateOfDeparture"></td>
                        <td data-bind="text: price.value + ' ' + price.currency"></td>
                        <td>
                            <a href='#' data-bind='click: $root.removeOffer'>Изтрий</a>
                        </td>
                        <td>
                            <a href='#' data-bind='click: $root.printOffer'>Отпечатай</a>
                        </td>
                    </tr>
                </tbody>
            </table>
        </form>
        <script src="scripts/GridView.js"></script>
    </body>
</html>
